#include<iostream>
#include<vector>
using namespace std;
int main(){
    int row,col;
    cin>>row>>col;
    if(row%2==0&&col%2==0){
        cout<<0<<endl;
        return 0;
    }
    vector<vector<int>>dp(row,vector<int>(col,0));
    dp[0][0]=1;
    for(int i=0;i<dp.size();i++){
        for(int j=0;j<dp[i].size();j++){
            if(i==0&&j==0)continue;
            if((i+1)%2==0&&(j+1)%2==0)continue;
            int up=i-1>=0?dp[i-1][j]:0;
            int left=j-1>=0?dp[i][j-1]:0;
            dp[i][j]+=(up+left);
        }
    }
    cout<<dp.back().back()<<endl;
    return 0;
}